namespace OasisCiq.Xal
{
    using System;
    using System.Linq;
    
    /// <summary>
    /// A list of locality name types such as Municipality, Village, Area, etc
    /// </summary>
    public class LocalityTypeList : XS.XSNormalizedString
    {
        private static readonly string[] PossibleValues = new[]
        {
            "Municipality",
            "PostTown",
            "Place",
            "Suburb",
            "Town",
            "Village",
            "Area",
            "Zone"
        };

        public LocalityTypeList(string value)
            : base(value)
        {
            if (!PossibleValues.Contains(value))
            {
                throw new ArgumentOutOfRangeException();
            }
        }
    }
}